﻿<!DOCTYPE html>

<html>

<head>
    <meta charset="utf-8">
    <title>后台管理模板</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="format-detection" content="telephone=no">

    <!--<link rel="stylesheet" href="plugins/layui/css/layui.css" media="all" />
    <link rel="stylesheet" href="css/global.css" media="all">
    <link rel="stylesheet" type="text/css" href="http://www.jq22.com/jquery/font-awesome.4.6.0.css">-->

</head>

<body>
    <div>
        WPF加载本地HTML，
    </div>
    <div>
        <a href="userList.html">用户页面</a>
    </div>
    <div style="margin:20px;">
        <label>请输入传给后台的参数：</label>
        <input type="text" id="txtName" />
        <input type="button" value="调用C#方法" onclick="callBack01()" />
    </div>
    <script type="text/javascript">//CefSharp.BindObjectAsync("csharpTest");

            (async function () {
                await CefSharp.BindObjectAsync("csharpTest");
            })();

			function callBack01() {
				try {
					var txtName = document.getElementById("txtName").value;

					//调用C#后台方法，方式一，无返回消息
                    csharpTest.showMsg(txtName);

                } catch (e) {
					alert(e);
                }
			}</script>
</body>

</html>
